home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CD ROM Paradise Collection 4
/
CD ROM Paradise Collection 4 1995 Nov.iso
/
science
/
vpcalc23.zip
/
WRITEFAC.VPC
< prev
Wrap
Text File
|
1991-09-08
|
758b
|
25 lines
@Echo off
Rem Start of WriteFac.VPC
Rem This VPCalc code file tests the Write and WriteLn Procedures of VPCalc
Rem by printing a table of factorials
Rem To run, start VPCalc.Exe. At Command: prompt, enter:
Rem ----->>>>> Run("WriteFac <<<<<-----;
Rem Harry Smith, 90/01/06.
Rem procedure WriteFac; X = N ! = 1*2*3*...*N
Rem Uses items N and Fac on the list
begin:
AutoDisplay(0)
48 m 0 t SetD(35)
WriteLn
WriteLn("Table of N Factorial ( N! = 1 * 2 * 3 * . . . * N )")
WriteLn
N = 0; Fac = 1;
Write(N); Write(" ! = "); Write(Fac); WriteLn;
Loop: N = N + 1; Fac = Fac * N; Write(N); Write(" ! = "); +
Write(Fac); WriteLn; if N < 100 GoUpTo Loop;
end:
Rem End of WriteFac.VPC